<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2021/6/21
  Time: 22:35
  To change this template use File | Settings | File Templates.
--%>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
%>
<ul class="nav-menu nav-menu-social align-to-right">
    <li class="add-listing green-bg">
        <c:if test="${user==null}">
            <a href="#" data-toggle="modal" data-target="#login">
                <i class="ti-user mr-1"></i> 登录
            </a>
        </c:if>
        <c:if test="${user!=null}">
            <a href="javascript:void(0);" data-target="#login">
                <i class="ti-user mr-1"></i> ${user.uname}
            </a>
        </c:if>
    </li>
</ul>